<template>
  <div >
    <Scroll :on-reach-bottom="handleReachBottom">
        <Timeline>
            <TimelineItem :key="item.id" v-for="item in timeLines">
                <p class="updateTime">{{item.updateTime}}</p>
                <p class="content">{{operationType[item.operationType]}}</p>
                <p class="content" v-if="item.feedback">{{item.feedback}}</p>
            </TimelineItem>
        </Timeline>
    </Scroll>

  </div>

</template>

<script>
export default {
  name: 'myTimeLine', // 注意这里的name命名，就是你以后封装好后使用的组件名
  props: {
    timeLines: []

  },
  data () {
    return {
      operationType: ['', '提交工单', '处理工单', '工单反馈', '取消工单']
    }
  },
  methods: {
    handleReachBottom () {
      this.$Message.info('我是有底线的')
    }
  }
}
</script>

<style scoped>
    .updateTime{
        font-size: 14px;
        font-weight: bold;
    }
    .content{
        padding-left: 5px;
    }
</style>
